package com.saas.util;

import java.io.IOException;
import java.util.Properties;

public class Env extends Properties {

    private static final long serialVersionUID = 1L;

    private static Env env = new Env();

    private Env() {
        super();
        try {
            load(getClass().getResourceAsStream("/db.properties"));
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }

    public static Env getInstance() {
        return env;
    }

    public static String get(String key) {
        return env.getProperty(key);
    }
}
